import http from '/@/utils/request'


/**
 * 新增工艺路线信息
 */
export const addCraftProcess = (data) => {
    return http.request({
        url: '/craft/add',
        method: 'put',
        data
    })
}
/**
 * 查询工艺路线信息列表
 */
export const listCraftProcess = (query) => {
    return http.request({
        url: '/craft/list',
        method:'get',
        params:query
    })
}
/**
 * 查询工艺路线信息详细
 */
export const getCraftProcessById = (id) => {
    return http.request({
        url: '/craft/info?id='+id,
        method:'get',
    })
}
/**
 * 查询工艺路线信息详细
 */
export const getCraftProcessInfo = (id) => {
    return http.request({
        url: '/craft/list.info?id='+id,
        method:'get',
    })
}

/**
 * 修改工艺路线信息
 */
export const updateCraftProcess = (data) => {
    return http.request({
        url: '/craft/update',
        method: 'put',
        data
    })
}

/**
 * 删除工艺路线信息
 */
export const delCraftProcess = (data) => {
    return http.request({
        url: '/craft/delete' ,
        method: 'put',
        data
    })
}
/**
 * 查询工艺路线下拉列表
 */
export const listCraftSelect = () => {
    return http.request({
        url: '/craft/list.select',
        method:'get',
        params:query
    })
}
